#ifndef ERROR_H
#define ERROR_H


typedef struct error {
    int		Ecode;
#define ERROR_PATH_MAX		128
    char	Path[ERROR_PATH_MAX];
    int 	Line;
#define ERROR_STRING_MAX	128
    char 	String[ERROR_STRING_MAX];
}Error;



struct error_interface {
    int (*Set)(Error *err, const char *file, int line, int ecode, const char *string);
    char *(*FullString)(const Error *err);
    char *(*String)(const Error *err);
    void (*FreeString)(char *string);
};

extern const struct error_interface moduleError;

#endif
